<?xml version="1.0"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html><head><title>com.lbi.typography.TypographyBase</title><script src="../../../quicknav.js" type="text/javascript"></script><script><!--
document.quicknavBasePath="../../../index-files";
//--></script><link href="../../../style.css" title="JavaDoc" rel="stylesheet" type="text/css"/><link href="../../../unnatural.css" title="Unnatural" rel="alternate stylesheet" type="text/css"/><link href="../../../overview-summary.html" title="Overview" rel="top"/><link href="package-summary.html" title="Package com.lbi.typography" rel="up"/><link href="../../../com/lbi/typography/TypographyHelper.html" title="Class com.lbi.typography.TypographyHelper" rel="prev"/><link href="../../../com/lbi/typography/StyleConverter.html" title="Class com.lbi.typography.StyleConverter" rel="next"/><meta name="generator" content="http://www.badgers-in-foil.co.uk/projects/as2api/"/></head><body><h1>Class com.lbi.typography.TypographyBase</h1><div class="type_hierachy"><ul><li><strong>com.lbi.typography.TypographyBase</strong></li></ul></div><div class="type_description"><h2>Description</h2><p>
	LBi Useful ActionScript 2 Library
    Copyright (C) 2007 LBi / Michael Forrest

    This library is free software; you can redistribute it and/or
    modify it under the terms of the GNU Lesser General Public
    License as published by the Free Software Foundation; either
    version 2.1 of the License, or (at your option) any later version.

    This library is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
    Lesser General Public License for more details.

    You should have received a copy of the GNU Lesser General Public
    License along with this library; if not, write to the Free Software
    Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 
 This class eschews the usual naming conventions in favour of something
 that looks a bit more like CSS. Override the Defaults() method to set the defaults.
 <pre>
 class app.helpers.Typography extends TypographyBase {

	private var WHITE : Number = 0xFFFFFF;

	private var ORANGE : Number = 0xF68B1E;

	function Typography(style:String) {
		super(style);
	}
	private function Defaults() : Void{
		font = Linkages.ARIAL;
		colour = WHITE;
	}
	private function H1() : Void{
		font_size = 24;
	}
	private function P() : Void{
		font_size = 12;
	}
	private function Footer() : Void{
		font_size = 16;
	}
	private function ItemHeading() : Void{
		font_size = 16;
		bold = true;
		colour = ORANGE;
	}

}
 </pre>

 </p></div><div class="type_indexes"><div class="field_index"><h2>Field Index</h2><a href="#align" title="public align:String">align</a>, <a href="#antiAliasType" title="public antiAliasType:String">antiAliasType</a>, <a href="#auto_size" title="public auto_size:String">auto_size</a>, <a href="#background" title="public background:Boolean">background</a>, <a href="#bold" title="public bold:Boolean">bold</a>, <a href="#border" title="public border:Boolean">border</a>, <a href="#colour" title="public colour:Number">colour</a>, <a href="#condense_white" title="public condense_white:Boolean">condense_white</a>, <a href="#embed_fonts" title="public embed_fonts:Boolean">embed_fonts</a>, <a href="#font" title="public font:String">font</a>, <a href="#font_size" title="public font_size:Number">font_size</a>, <a href="#gridFitType" title="public gridFitType:String">gridFitType</a>, <a href="#html" title="public html:Boolean">html</a>, <a href="#indent" title="public indent:Number">indent</a>, <a href="#italic" title="public italic:Boolean">italic</a>, <a href="#leading" title="public leading:Number">leading</a>, <a href="#left_margin" title="public left_margin:Number">left_margin</a>, <a href="#letterSpacing" title="public letterSpacing:Number">letterSpacing</a>, <a href="#multiline" title="public multiline:Boolean">multiline</a>, <a href="#right_margin" title="public right_margin:Number">right_margin</a>, <a href="#selectable" title="public selectable:Boolean">selectable</a>, <a href="#sharpness" title="public sharpness:Number">sharpness</a>, <a href="#target" title="public target:String">target</a>, <a href="#thickness" title="public thickness:Number">thickness</a>, <a href="#type" title="public type:String">type</a>, <a href="#underline" title="public underline:Boolean">underline</a>, <a href="#url" title="public url:String">url</a>, <a href="#word_wrap" title="public word_wrap:Boolean">word_wrap</a></div><div class="method_index"><h2>Method Index</h2><div><code>new <a href="#TypographyBase" title="public function TypographyBase(style:String)">TypographyBase()</a></code></div><a href="#changeStyle" title="public function changeStyle(txt:TextField, style:Function):Void">changeStyle()</a>, <a href="#Defaults" title="public function Defaults():Void">Defaults()</a>, <a href="#getTextFieldParams" title="public function getTextFieldParams():Object">getTextFieldParams()</a>, <a href="#getTextFormat" title="public function getTextFormat():TextFormat">getTextFormat()</a></div></div><div class="type_details"><div class="constructor_detail_list"><h2>Constructor Detail</h2><div class="method_details"><a name="TypographyBase"></a><h3>TypographyBase</h3><code class="method_synopsis">public function <strong class="method_name">TypographyBase</strong>(style:<span class="unresolved_type_name">String</span>)</code><div class="method_info"></div></div></div><div class="field_detail_list"><h2>Field Detail</h2><a name="font_size"></a><h3>font_size</h3><div class="field_details"><code class="field_synopsis">public <strong class="field_name">font_size</strong>:<span class="unresolved_type_name">Number</span></code></div><a name="font"></a><h3>font</h3><div class="field_details"><code class="field_synopsis">public <strong class="field_name">font</strong>:<span class="unresolved_type_name">String</span></code></div><a name="colour"></a><h3>colour</h3><div class="field_details"><code class="field_synopsis">public <strong class="field_name">colour</strong>:<span class="unresolved_type_name">Number</span></code></div><a name="bold"></a><h3>bold</h3><div class="field_details"><code class="field_synopsis">public <strong class="field_name">bold</strong>:<span class="unresolved_type_name">Boolean</span></code></div><a name="italic"></a><h3>italic</h3><div class="field_details"><code class="field_synopsis">public <strong class="field_name">italic</strong>:<span class="unresolved_type_name">Boolean</span></code></div><a name="underline"></a><h3>underline</h3><div class="field_details"><code class="field_synopsis">public <strong class="field_name">underline</strong>:<span class="unresolved_type_name">Boolean</span></code></div><a name="url"></a><h3>url</h3><div class="field_details"><code class="field_synopsis">public <strong class="field_name">url</strong>:<span class="unresolved_type_name">String</span></code></div><a name="target"></a><h3>target</h3><div class="field_details"><code class="field_synopsis">public <strong class="field_name">target</strong>:<span class="unresolved_type_name">String</span></code></div><a name="align"></a><h3>align</h3><div class="field_details"><code class="field_synopsis">public <strong class="field_name">align</strong>:<span class="unresolved_type_name">String</span></code></div><a name="left_margin"></a><h3>left_margin</h3><div class="field_details"><code class="field_synopsis">public <strong class="field_name">left_margin</strong>:<span class="unresolved_type_name">Number</span></code></div><a name="right_margin"></a><h3>right_margin</h3><div class="field_details"><code class="field_synopsis">public <strong class="field_name">right_margin</strong>:<span class="unresolved_type_name">Number</span></code></div><a name="indent"></a><h3>indent</h3><div class="field_details"><code class="field_synopsis">public <strong class="field_name">indent</strong>:<span class="unresolved_type_name">Number</span></code></div><a name="leading"></a><h3>leading</h3><div class="field_details"><code class="field_synopsis">public <strong class="field_name">leading</strong>:<span class="unresolved_type_name">Number</span></code></div><a name="auto_size"></a><h3>auto_size</h3><div class="field_details"><code class="field_synopsis">public <strong class="field_name">auto_size</strong>:<span class="unresolved_type_name">String</span></code></div><a name="background"></a><h3>background</h3><div class="field_details"><code class="field_synopsis">public <strong class="field_name">background</strong>:<span class="unresolved_type_name">Boolean</span></code></div><a name="html"></a><h3>html</h3><div class="field_details"><code class="field_synopsis">public <strong class="field_name">html</strong>:<span class="unresolved_type_name">Boolean</span></code></div><a name="word_wrap"></a><h3>word_wrap</h3><div class="field_details"><code class="field_synopsis">public <strong class="field_name">word_wrap</strong>:<span class="unresolved_type_name">Boolean</span></code></div><a name="multiline"></a><h3>multiline</h3><div class="field_details"><code class="field_synopsis">public <strong class="field_name">multiline</strong>:<span class="unresolved_type_name">Boolean</span></code></div><a name="condense_white"></a><h3>condense_white</h3><div class="field_details"><code class="field_synopsis">public <strong class="field_name">condense_white</strong>:<span class="unresolved_type_name">Boolean</span></code></div><a name="border"></a><h3>border</h3><div class="field_details"><code class="field_synopsis">public <strong class="field_name">border</strong>:<span class="unresolved_type_name">Boolean</span></code></div><a name="selectable"></a><h3>selectable</h3><div class="field_details"><code class="field_synopsis">public <strong class="field_name">selectable</strong>:<span class="unresolved_type_name">Boolean</span></code></div><a name="embed_fonts"></a><h3>embed_fonts</h3><div class="field_details"><code class="field_synopsis">public <strong class="field_name">embed_fonts</strong>:<span class="unresolved_type_name">Boolean</span></code></div><a name="type"></a><h3>type</h3><div class="field_details"><code class="field_synopsis">public <strong class="field_name">type</strong>:<span class="unresolved_type_name">String</span></code></div><a name="antiAliasType"></a><h3>antiAliasType</h3><div class="field_details"><code class="field_synopsis">public <strong class="field_name">antiAliasType</strong>:<span class="unresolved_type_name">String</span></code><div class="field_info">
 Flash 8 only
 Can be "normal" or "advanced".
 <h4>See Also</h4><ul class="extra_info"><li><span class="unresolved_type_name">gridFitType,</span></li></ul></div></div><a name="gridFitType"></a><h3>gridFitType</h3><div class="field_details"><code class="field_synopsis">public <strong class="field_name">gridFitType</strong>:<span class="unresolved_type_name">String</span></code><div class="field_info">
 Flash 8 only
 Can be "none", "pixel" or "subpixel"
	 </div></div><a name="thickness"></a><h3>thickness</h3><div class="field_details"><code class="field_synopsis">public <strong class="field_name">thickness</strong>:<span class="unresolved_type_name">Number</span></code><div class="field_info">
 Flash 8 only
 In range -200 to 200
 The thickness of the glyph edges in this TextField
 instance. This property applies only
 when antiAliasType() is set to "advanced".
	 </div></div><a name="sharpness"></a><h3>sharpness</h3><div class="field_details"><code class="field_synopsis">public <strong class="field_name">sharpness</strong>:<span class="unresolved_type_name">Number</span></code><div class="field_info">
 Flash 8 only
 The range for sharpness is a number from -400 to 400.
	 </div></div><a name="letterSpacing"></a><h3>letterSpacing</h3><div class="field_details"><code class="field_synopsis">public <strong class="field_name">letterSpacing</strong>:<span class="unresolved_type_name">Number</span></code><div class="field_info">
 Flash 8 only
 The amount of space that is uniformly distributed between characters.
	 </div></div></div><div class="method_detail_list"><h2>Method Detail</h2><div class="method_details alt_row"><a name="changeStyle"></a><h3>changeStyle</h3><code class="method_synopsis">public function <strong class="method_name">changeStyle</strong>(txt:<span class="unresolved_type_name">TextField</span>, style:<span class="unresolved_type_name">Function</span>):<span class="void_name">Void</span></code><div class="method_info"></div></div><div class="method_details"><a name="Defaults"></a><h3>Defaults</h3><code class="method_synopsis">public function <strong class="method_name">Defaults</strong>():<span class="void_name">Void</span></code><div class="method_info"></div></div><div class="method_details alt_row"><a name="getTextFormat"></a><h3>getTextFormat</h3><code class="method_synopsis">public function <strong class="method_name">getTextFormat</strong>():<span class="unresolved_type_name">TextFormat</span></code><div class="method_info"></div></div><div class="method_details"><a name="getTextFieldParams"></a><h3>getTextFieldParams</h3><code class="method_synopsis">public function <strong class="method_name">getTextFieldParams</strong>():<span class="unresolved_type_name">Object</span></code><div class="method_info"></div></div></div></div><ul class="main_nav" id="main_nav"><li><a href="../../../overview-summary.html" title="Overview of API" class="button">Overview</a></li><li><a href="package-summary.html" title="Overview of package com.lbi.typography" class="button">Package</a></li><li><span class="button nav_current">Class</span></li><li><a href="../../../index-files/index.html" title="Alpabetical index of types and members" class="button">Index</a></li></ul><div class="footer"><a href="http://www.badgers-in-foil.co.uk/projects/as2api/" title="ActionScript 2 API Documentation Generator">as2api</a></div></body></html>